#ifndef RP2CULLSTATE_H
#define RP2CULLSTATE_H

#include "Rp2GlobalState.h"

namespace Rp2
{
	
class CullState : public GlobalState
{
RP2_DECLARE_INITIALIZE;
RP2_DECLARE_TERMINATE;

public:
	CullState();
	virtual ~CullState();

	virtual StateType GetStateType() const { return CULL; }

    enum FrontMode
    {
        FT_CCW,  // front faces are counterclockwise ordered
        FT_CW,   // front faces are clockwise ordered
        FT_QUANTITY
    };

    enum CullMode
    {
        CT_FRONT,  // cull front-facing triangles
        CT_BACK,   // cull back-facing triangles
        CT_QUANTITY
    };

    bool Enabled;         // default: true
    FrontMode FrontFace;  // default: FT_CCW
    CullMode CullFace;    // default: CT_BACK
};

RP2_REGISTER_INITIALIZE(CullState);
RP2_REGISTER_TERMINATE(CullState);
typedef Pointer<CullState> CullStatePtr;

}

#endif